-
Notifications
You must be signed in to change notification settings - Fork 118
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
add check for shared volumes in getVolumeStats #2419
add check for shared volumes in getVolumeStats #2419
Conversation
Signed-off-by: dahuang <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm after comment is addressed
@@ -365,7 +365,8 @@ func (s *OsdCsiServer) NodeGetVolumeStats(ctx context.Context, req *csi.NodeGetV | |||
|
|||
var attachPathMatch bool |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In general, I don't understand the reason for this path match check. Regardless of the attachPath we can always return the volume usage for every volume. The attach path does not dictate the volume usage.
b4ed691
to
b015850
Compare
chatted with @adityadani offline. Removing the attach_path check will break how CSI sanity, so let's keep the attach_path validation. |
Signed-off-by: dahuang <[email protected]>
* add check for shared volumes in getVolumeStats Adds check for shared v4 volumes that have a different attach path than the assumed CSI volume path. JIRA: PWX-35351 Signed-off-by: dahuang <[email protected]>
Signed-off-by: dahuang <[email protected]>
* add check for shared volumes in getVolumeStats (#2419) Adds check for shared v4 volumes that have a different attach path than the assumed CSI volume path. JIRA: PWX-35351 Signed-off-by: dahuang <[email protected]>
* add check for shared volumes in getVolumeStats Adds check for shared v4 volumes that have a different attach path than the assumed CSI volume path. JIRA: PWX-35351 Signed-off-by: dahuang <[email protected]>
What this PR does / why we need it:
Adds check for shared v4 volumes that have a different attach path than the assumed CSI volume path.
Which issue(s) this PR fixes (optional)
PWX-35351
Testing Notes

With the fix, we are able to see Used Space on OCP: